<rich:page xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:o="http://openfaces.org/"
	xmlns:rich="http://richfaces.org/rich"
	xmlns:a4j="http://richfaces.org/a4j" markupType="xhtml"
	xmlns:s="http://jboss.com/products/seam/taglib" contentType="text/html"
	theme="simple" sidebarWidth="200" sidebarPosition="left">

	<f:facet name="header">
		<ui:include src="/WEB-INF/esquema/header.xhtml"/>
	</f:facet>

	<f:facet name="sidebar">
		<ui:include src="/WEB-INF/esquema/sidebar2.xhtml"/>
	</f:facet>
	
	<f:facet name="footer">
		<ui:include src="/WEB-INF/esquema/footer.xhtml"/>
	</f:facet>

	<rich:panel id="bodyPanel">
        <ui:include src="/WEB-INF/includes/util/blockPage.xhtml"/>
		
		<rich:toolBar height="25" itemSeparator="line">
			<rich:toolBarGroup>
				<ui:insert name="mainControls"/>
			</rich:toolBarGroup>
			<rich:toolBarGroup>
				<ui:insert name="extraControls"/>
			</rich:toolBarGroup>
			<rich:toolBarGroup rendered="#{view.viewId != '/workflow/transaction/presentation.xhtml'}">
				<h:form>
					<a4j:commandButton value="#{messages['options.view_request']}" reRender="transactionData"
					oncomplete="#{rich:component('viewRequestPanel')}.show()"
					rendered="#{view.viewId != '/workflow/transaction/approval.xhtml'}">
						<f:setPropertyActionListener value="#{true}" target="#{viewTransactionHelper.renderTransactionData}" />
					</a4j:commandButton>
					
					<a4j:commandButton value="#{messages['intro2.attacheddocs']}"
					oncomplete="#{rich:component('attachedFilesDlg')}.show()">
					</a4j:commandButton>
				</h:form>
			</rich:toolBarGroup>
		</rich:toolBar>
		
		
		<br />
		<ui:insert name="body" />
		<br />
		
		
		<rich:toolBar height="25" itemSeparator="line">
			<rich:toolBarGroup>
				<ui:insert name="mainControls"/>
			</rich:toolBarGroup>
			<rich:toolBarGroup>
				<ui:insert name="extraControls"/>
			</rich:toolBarGroup>
			<rich:toolBarGroup rendered="#{view.viewId != '/workflow/transaction/presentation.xhtml'}">
				<h:form>
					<a4j:commandButton value="#{messages['options.view_request']}" reRender="transactionData"
					oncomplete="#{rich:component('viewRequestPanel')}.show()"
					rendered="#{view.viewId != '/workflow/transaction/approval.xhtml'}">
						<f:setPropertyActionListener value="#{true}" target="#{viewTransactionHelper.renderTransactionData}" />
					</a4j:commandButton>
					
					<a4j:commandButton value="#{messages['intro2.attacheddocs']}"
					oncomplete="#{rich:component('attachedFilesDlg')}.show()">
					</a4j:commandButton>
				</h:form>
			</rich:toolBarGroup>
		</rich:toolBar>

        <ui:include src="/WEB-INF/includes/modalPanels.xhtml"/>
		<ui:include
			src="/workflow/transaction/includes/attachedFilesDlg.xhtml"
			rendered="#{view.viewId != '/workflow/transaction/presentation.xhtml'}">
		</ui:include>
		
		<ui:insert name="extraIncludes"/>
	</rich:panel>
</rich:page>
